package com.example.demo.aspect;

import lombok.extern.slf4j.Slf4j;
import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;

@Slf4j
@Aspect
//@Component
@Order(1)
public class AspectDemo3 {
    // 前置通知
     @Before("com.example.demo.aspect.AspectDemo1.pt()")
    public void doBefore() {
         log.info("AspectDemo3 doBefore...");
    }

    // 后置通知
    @After("com.example.demo.aspect.AspectDemo1.pt()")
    public void doAfter() {
        log.info("AspectDemo3 doAfter...");
    }
}
